{%- extends "base.html" %}

{%- block title %}
{% trans %}Manager list{% endtrans %}
{%- endblock %}

{%- block subtitle %}
{{ domain.name }}
{%- endblock %}

{%- block main_action %}
<a class="btn btn-primary float-right" href="{{ url_for('.manager_create', domain_name=domain.name) }}">{% trans %}Add manager{% endtrans %}</a>
{%- endblock %}

{%- block content %}
{%- call macros.table(order='[[1,"asc"]]') %}
<thead>
  <tr>
    <th data-orderable="false">{% trans %}Actions{% endtrans %}</th>
    <th>{% trans %}Email{% endtrans %}</th>
  </tr>
</thead>
<tbody>
{%- for manager in domain.managers %}
<tr>
  <td>
    <a href="{{ url_for('.user_edit', user_email=manager.email) }}" title="{% trans %}Edit{% endtrans %}"><i class="fas fa-pencil-alt"></i></a>&nbsp;
    <a href="{{ url_for('.manager_delete', domain_name=domain.name, user_email=manager.email) }}" title="{% trans %}Delete{% endtrans %}"><i class="fa fa-trash"></i></a>
  </td>
  <td>{{ manager }}</td>
</tr>
{%- endfor %}
</tbody>
{%- endcall %}
{%- endblock %}
